package com.sx.pipeline.ui.setting.service

import android.text.TextUtils
import android.view.LayoutInflater
import android.view.View
import android.view.ViewGroup
import com.alibaba.android.arouter.facade.annotation.Route
import com.blankj.utilcode.util.ToastUtils
import com.sx.mvvmlibs.base.NoVMBaseActivity
import com.sx.pipeline.BR
import com.sx.pipeline.R
import com.sx.pipeline.arouth.RoutePath
import com.sx.pipeline.databinding.ActContactServiceBinding


/**
 * @Author: YY
 * @Date: 2022/4/5
 * @Description: 联系客服
 */
//@Route(path = RoutePath.Setting.CONTACT_SERVICE)
class ContactServiceActivity : NoVMBaseActivity<ActContactServiceBinding>(), View.OnClickListener {

    override fun initBinding(inflater: LayoutInflater, container: ViewGroup?) =
        ActContactServiceBinding.inflate(inflater)

    override fun initData() {
        mBinding.setVariable(BR.onClick, this)
        mBinding.titleBar.leftView.setOnClickListener {
            finish()
        }
    }

    override fun onClick(v: View?) {
        when (v?.id) {
            R.id.tv_submit -> {
                if (TextUtils.isEmpty(mBinding.etInput.text.toString())) {
                    ToastUtils.showShort("请填写内容")
                    return
                }
                ToastUtils.showShort("提交成功")
                finish()
            }
        }
    }

}